package com.linln.admin.app.domain;

import com.linln.common.utils.StatusUtil;
import lombok.Data;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.Where;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import java.io.Serializable;
import javax.persistence.*;

/**
 * @author 陶富成
 * @date 2021/07/08
 */
@Data
@Entity
@Table(name = "app_info")
@EntityListeners(AuditingEntityListener.class)
@Where(clause = StatusUtil.NOT_DELETE)
@DynamicInsert
@DynamicUpdate
public class AppInfo implements Serializable {
    // 项目名称
    private String display_name;
    // 代码仓库类型
    private String repo_type;
    // 代码仓库对应的账号
    private Long repo_account_id;
    // 所以产品线
    private Long prod_line_id;
    // 代码仓库URL
    private String repo_url;
    //基线分支名或基线url，默认值:prod
    private String base;
    /**
     * 主键
     */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    private Byte status;
}